(global.webpackJsonp = global.webpackJsonp || []).push([ [ "shop/order/orderDetail" ], {
    "137d": function(e, t, r) {
        r.r(t);
        var o = r("eac0"), n = r.n(o);
        for (var a in o) "default" !== a && function(e) {
            r.d(t, e, function() {
                return o[e];
            });
        }(a);
        t.default = n.a;
    },
    "2ff2": function(e, t, r) {
        var o = r("f553");
        r.n(o).a;
    },
    c0e0: function(e, t, r) {
        r.d(t, "b", function() {
            return o;
        }), r.d(t, "c", function() {
            return n;
        }), r.d(t, "a", function() {});
        var o = function() {
            var e = this, t = (e.$createElement, e._self._c, e.isTrue && "1" == e.order.state.state_code ? e.__get_style([ e.liner ]) : null), r = e.isTrue && "3" == e.order.state.state_code ? e.__get_style([ e.liner ]) : null, o = e.isTrue && "4" == e.order.state.state_code && "0" == e.order.is_comment ? e.__get_style([ e.liner ]) : null, n = e.isTrue && 1 == e.order.sale_state && 1 == e.order.refund_state && 5 == e.order.state.state_code && 1 == e.order.shouhou_state ? e.__get_style([ e.liner ]) : null, a = e.isTrue && 1 == e.order.sale_state && 2 == e.order.refund_state && 5 == e.order.state.state_code && 1 == e.order.shouhou_state ? e.__get_style([ e.liner ]) : null, s = e.isTrue && 1 == e.order.sale_state && 3 == e.order.refund_state && 5 == e.order.state.state_code && 1 == e.order.shouhou_state && 1 == e.order.refund_result ? e.__get_style([ e.liner ]) : null, i = e.isTrue && 1 == e.order.sale_state && 3 == e.order.refund_state && 5 == e.order.state.state_code && 2 == e.order.refund_result ? e.__get_style([ e.liner ]) : null, u = e.isTrue && 1 == e.order.sale_state && 3 == e.order.refund_state && 5 == e.order.state.state_code && 2 == e.order.shouhou_state ? e.__get_style([ e.liner ]) : null;
            e.$mp.data = Object.assign({}, {
                $root: {
                    s0: t,
                    s1: r,
                    s2: o,
                    s3: n,
                    s4: a,
                    s5: s,
                    s6: i,
                    s7: u
                }
            });
        }, n = [];
    },
    c833: function(e, t, r) {
        (function(e) {
            r("1067"), o(r("66fd"));
            var t = o(r("ef72"));
            function o(e) {
                return e && e.__esModule ? e : {
                    default: e
                };
            }
            wx.__webpack_require_UNI_MP_PLUGIN__ = r, e(t.default);
        }).call(this, r("543d").createPage);
    },
    eac0: function(e, t, r) {
        (function(e) {
            Object.defineProperty(t, "__esModule", {
                value: !0
            }), t.default = void 0;
            var o = r("26cb"), n = (r("a71e"), r("8434")), a = (function(e) {
                e && e.__esModule;
            }(r("03b8")), r("8f9b")), s = r("9b04"), i = r("db8f"), u = r("0cc1");
            function c(e, t) {
                var r;
                if ("undefined" == typeof Symbol || null == e[Symbol.iterator]) {
                    if (Array.isArray(e) || (r = function(e, t) {
                        if (e) {
                            if ("string" == typeof e) return d(e, t);
                            var r = Object.prototype.toString.call(e).slice(8, -1);
                            return "Object" === r && e.constructor && (r = e.constructor.name), "Map" === r || "Set" === r ? Array.from(e) : "Arguments" === r || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r) ? d(e, t) : void 0;
                        }
                    }(e)) || t && e && "number" == typeof e.length) {
                        r && (e = r);
                        var o = 0, n = function() {};
                        return {
                            s: n,
                            n: function() {
                                return o >= e.length ? {
                                    done: !0
                                } : {
                                    done: !1,
                                    value: e[o++]
                                };
                            },
                            e: function(e) {
                                throw e;
                            },
                            f: n
                        };
                    }
                    throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
                }
                var a, s = !0, i = !1;
                return {
                    s: function() {
                        r = e[Symbol.iterator]();
                    },
                    n: function() {
                        var e = r.next();
                        return s = e.done, e;
                    },
                    e: function(e) {
                        i = !0, a = e;
                    },
                    f: function() {
                        try {
                            s || null == r.return || r.return();
                        } finally {
                            if (i) throw a;
                        }
                    }
                };
            }
            function d(e, t) {
                (null == t || t > e.length) && (t = e.length);
                for (var r = 0, o = new Array(t); r < t; r++) o[r] = e[r];
                return o;
            }
            function l(e, t) {
                var r = Object.keys(e);
                if (Object.getOwnPropertySymbols) {
                    var o = Object.getOwnPropertySymbols(e);
                    t && (o = o.filter(function(t) {
                        return Object.getOwnPropertyDescriptor(e, t).enumerable;
                    })), r.push.apply(r, o);
                }
                return r;
            }
            function f(e) {
                for (var t = 1; t < arguments.length; t++) {
                    var r = null != arguments[t] ? arguments[t] : {};
                    t % 2 ? l(Object(r), !0).forEach(function(t) {
                        _(e, t, r[t]);
                    }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(r)) : l(Object(r)).forEach(function(t) {
                        Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(r, t));
                    });
                }
                return e;
            }
            function _(e, t, r) {
                return t in e ? Object.defineProperty(e, t, {
                    value: r,
                    enumerable: !0,
                    configurable: !0,
                    writable: !0
                }) : e[t] = r, e;
            }
            var h = "", p = {
                components: {},
                data: function() {
                    return {
                        id: "",
                        isTrue: !1,
                        order: {},
                        shops: [],
                        payData: {
                            type: 1,
                            money: "",
                            pay: ""
                        },
                        payType: "",
                        isPay: -1
                    };
                },
                computed: f(f({}, (0, o.mapGetters)([ "mainColor", "configs", "priceColor", "iphoneXStyle" ])), {}, {
                    liner: function() {
                        return {
                            border: "0px solid " + this.configs.btn2BgColor,
                            color: "#fff",
                            background: this.configs.btn2BgColor
                        };
                    }
                }),
                onShow: function() {
                    this.getDetail();
                },
                onLoad: function(e) {
                    e && (this.id = e.id, this.order_id = e.order_id);
                },
                created: function() {
                    this.isPayType(), h = this;
                },
                methods: {
                    isPayType: function() {
                        var e = this;
                        (0, s.payMethod)().then(function(t) {
                            -1 == t.indexOf("wxpay") && (e.isPay = 0);
                        });
                    },
                    choosePay: function(e) {
                        this.isPay = 1 == e.typeId ? 3 : 2, this.Order();
                    },
                    Mail: function() {
                        (0, n.route)({
                            url: "/shop/order/mail",
                            type: 1,
                            data: {
                                id: this.id
                            }
                        });
                    },
                    pullTk: function() {
                        (0, n.route)({
                            url: "/shop/order/refund",
                            type: 1,
                            data: {
                                id: this.id
                            }
                        });
                    },
                    toMsg: function() {
                        (0, n.route)({
                            url: "/pages/contact/contact",
                            type: 1,
                            data: {}
                        });
                    },
                    evaluation: function() {
                        (0, n.route)({
                            url: "/shop/order/appraise",
                            type: 1,
                            data: {
                                id: this.id,
                                type: 2
                            }
                        });
                    },
                    Logistics: function() {
                        (0, n.route)({
                            url: "/shop/order/logistics",
                            type: 1,
                            data: {
                                id: this.id
                            }
                        });
                    },
                    confirm: function() {
                        var t = this;
                        e.showModal({
                            title: "提示",
                            content: "请确定是否收货？",
                            cancelText: "取消",
                            confirmText: "确定",
                            success: function(e) {
                                e.confirm && t.confirms();
                            }
                        });
                    },
                    confirms: function() {
                        var e = this, t = {
                            order_id: e.id
                        };
                        (0, a.goodOrderConfirm)(t).then(function(t) {
                            e.$toast("收货成功", "none"), setTimeout(function() {
                                (0, n.route)({
                                    url: "/shop/order/orderList",
                                    type: 3,
                                    data: {}
                                });
                            }, 200);
                        });
                    },
                    putOrder: (0, i.throttle)(function() {
                        h.Order();
                    }, 1500),
                    cacalOrder: function() {
                        var t = this;
                        e.showModal({
                            title: "提示",
                            content: "请确定是否取消订单？",
                            cancelText: "取消",
                            confirmText: "确定",
                            success: function(e) {
                                e.confirm && t.cacelOrder();
                            }
                        });
                    },
                    cacelOrder: function() {
                        var e = this, t = {
                            id: e.id,
                            user_id: e.user_id
                        };
                        (0, a.goodOrderCancel)(t).then(function(t) {
                            e.$toast("取消成功", "none"), setTimeout(function() {
                                (0, n.route)({
                                    url: "/shop/order/orderList",
                                    type: 3,
                                    data: {}
                                });
                            }, 200);
                        });
                    },
                    coptData: function(t, r) {
                        if (2 == r) {
                            var o, n = this, a = "", s = c(t);
                            try {
                                for (s.s(); !(o = s.n()).done; ) {
                                    var i = o.value;
                                    a = a + i.key + "：" + i.value + "；";
                                }
                            } catch (e) {
                                s.e(e);
                            } finally {
                                s.f();
                            }
                            e.setClipboardData({
                                data: a,
                                success: function() {
                                    n.$toast("复制成功", "none");
                                }
                            });
                        } else {
                            var u = this;
                            e.setClipboardData({
                                data: t,
                                success: function() {
                                    u.$toast("复制成功", "none");
                                }
                            });
                        }
                    },
                    getDetail: function() {
                        var e = this, t = this, r = {
                            id: this.id
                        };
                        (0, a.goodOrderInfo)(r).then(function(r) {
                            switch (t.order = r, r.pay_type) {
                              case "1":
                                r.pay_type = "微信支付";
                                break;

                              case "0":
                                r.pay_type = "余额支付";
                            }
                            switch (r.state) {
                              case "1":
                                t.order.msg = "待付款", r.auto_cancel_time.length > 1 && (t.order.time = r.auto_cancel_time);
                                break;

                              case "2":
                                t.order.msg = "待发货";
                                break;

                              case "3":
                                t.order.msg = "待收货";
                                break;

                              case "4":
                              case "4":
                                t.order.msg = "已完成";
                                break;

                              case "0":
                                t.order.msg = "已自动取消";
                            }
                            e.shops = r.good_list, e.isTrue = !0, 1 == r.sale_state && 1 == r.refund_state && 5 == r.state && 0 == r.shouhou_state || 1 == r.sale_state && 2 == r.refund_state && 5 == r.state && 1 == r.shouhou_state ? t.order.msg = "等待平台审核退款" : 1 == r.sale_state && 3 == r.refund_state && 5 == r.state.state_code && 1 == r.shouhou_state ? t.order.msg = "退款成功" : 1 == r.sale_state && 3 == r.refund_state && 5 == r.state.state_code && 0 == r.is_refund || 1 == r.sale_state && 3 == r.refund_state && 5 == r.state.state_code && 2 == r.shouhou_state ? t.order.msg = "拒绝退款" : 1 == r.sale_state && 1 == r.refund_state && 5 == r.state.state_code && 1 == r.shouhou_state && (t.order.msg = "邮寄商品");
                        });
                    },
                    Order: function() {
                        var e = this;
                        if (0 == e.isPay) return e.$toast("未设置支付方式", "none"), !1;
                        var t = {
                            payType: 1,
                            order_id: e.id
                        };
                        (0, a.submitGoodOrder)(t).then(function(t) {
                            (0, u.pay)(t, e.orderSuccess, e.orderFail, "");
                        });
                    },
                    orderSuccess: function() {
                        (0, n.route)({
                            url: "/shop/order/orderList",
                            type: 3,
                            data: {}
                        });
                    },
                    orderFail: function() {},
                    onPullDownRefresh: function() {
                        this.getDetail();
                    }
                }
            };
            t.default = p;
        }).call(this, r("543d").default);
    },
    ef72: function(e, t, r) {
        r.r(t);
        var o = r("c0e0"), n = r("137d");
        for (var a in n) "default" !== a && function(e) {
            r.d(t, e, function() {
                return n[e];
            });
        }(a);
        r("2ff2");
        var s = r("f0c5"), i = Object(s.a)(n.default, o.b, o.c, !1, null, "7ea29ec1", null, !1, o.a, void 0);
        t.default = i.exports;
    },
    f553: function(e, t, r) {}
}, [ [ "c833", "common/runtime", "common/vendor" ] ] ]);